using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ACME.Northwind.DataTransfer;
using ACME.Northwind.Service.Interfaces;

namespace ACME.Northwind.MockProxy.EventArgs
{
	#region Category EventArgs

	/// <summary>
	/// An event arguments class for object selection by primary key
	/// </summary>
	public partial class CategoryPrimaryKeyEventArgs : System.EventArgs
	{
		/// <summary>
		/// The default constructor
		/// </summary>
		public CategoryPrimaryKeyEventArgs(int categoryid)
		{
			this.ReturnValue = new CategoryDTO();
		}

		/// <summary>
		/// The returned DTO item
		/// </summary>
		public CategoryDTO ReturnValue { get; set; }
	}

	/// <summary>
	/// An event arguments class for object persistence
	/// </summary>
	public partial class CategoryPersistEventArgs : System.EventArgs
	{
		/// <summary>
		/// The constructor for single DTO events
		/// </summary>
		public CategoryPersistEventArgs(CategoryDTO dto)
		{
			this.DTOList = new List<CategoryDTO>();
			this.DTOList.Add(dto);
		}

		/// <summary>
		/// The constructor for multi DTO events
		/// </summary>
		public CategoryPersistEventArgs(List<CategoryDTO> list)
		{
			this.DTOList = list;
		}

		/// <summary>
		/// The list of DTO items to persist
		/// </summary>
		public List<CategoryDTO> DTOList { get; set; }
		/// <summary>
		/// The return value for success
		/// </summary>
		public bool ReturnValue { get; set; }
	}

	/// <summary>
	/// An event arguments class for object deletion
	/// </summary>
	public partial class CategoryDeleteEventArgs : CategoryPersistEventArgs
	{
		/// <summary>
		/// The constructor for single DTO events
		/// </summary>
		public CategoryDeleteEventArgs(CategoryDTO dto) : base(dto)
		{
		}

		/// <summary>
		/// The constructor for multi DTO events
		/// </summary>
		public CategoryDeleteEventArgs(List<CategoryDTO> list) : base (list)
		{
		}

	}

	/// <summary>
	/// An event arguments class for object selection
	/// </summary>
	public partial class CategoryRunSelectEventArgs : System.EventArgs
	{
		/// <summary>
		/// The default constructor
		/// </summary>
		public CategoryRunSelectEventArgs()
		{
			this.ReturnValue = new List<CategoryDTO>();
		}

		/// <summary>
		/// The returned list of DTO items
		/// </summary>
		public List<CategoryDTO> ReturnValue { get; set; }
	}

	/// <summary>
	/// An event arguments class for object selection with LINQ
	/// </summary>
	public partial class CategoryRunSelectLINQEventArgs : CategoryRunSelectEventArgs
	{
		/// <summary>
		/// The default constructor
		/// </summary>
		public CategoryRunSelectLINQEventArgs(string linq)
			: base()
		{
			this.LINQ = linq;
		}
		
		/// <summary>
		/// The LINQ statement to use for filtering
		/// </summary>
		public string LINQ { get; set; }
	}

	/// <summary>
	/// An event arguments class for paginated object selection
	/// </summary>
	public partial class CategoryRunSelectPagedEventArgs : System.EventArgs
	{
		/// <summary>
		/// The default constructor
		/// </summary>
		public CategoryRunSelectPagedEventArgs(int pageIndex, int pageSize, bool ascending, string sortColumn, string linq)			
		{
			this.ReturnValue = new PagedQueryResults<CategoryDTO>();
			this.PageIndex = pageIndex;
			this.PageSize = pageSize;
			this.Ascending = ascending;
			this.SortColumn = sortColumn;
			this.LINQ = linq;
		}

		/// <summary>
		/// The returned list of DTO items
		/// </summary>
		public PagedQueryResults<CategoryDTO> ReturnValue { get; set; }
		/// <summary>
		/// The LINQ statement to use for filtering
		/// </summary>
		public string LINQ { get; set; }
		/// <summary>
		/// The page index to load
		/// </summary>
		public int PageIndex { get; set; }
		/// <summary>
		/// The number of records per page
		/// </summary>
		public int PageSize { get; set; }
		/// <summary>
		/// Determines if the sort direction
		/// </summary>
		public bool Ascending { get; set; }
		/// <summary>
		/// Determines the column on which to sort
		/// </summary>
		public string SortColumn { get; set; }
	}

	/// <summary>
	/// An event arguments class for DTO specific events
	/// </summary>
	public partial class CategoryDTOEventArgs : System.EventArgs
	{
		/// <summary>
		/// The default constructor
		/// </summary>
		public CategoryDTOEventArgs(CategoryDTO item)
		{
			this.DTO = item;
		}

		/// <summary>
		/// The passed in DTO item
		/// </summary>
		public CategoryDTO DTO { get; set; }
		/// <summary>
		/// The returned DTO item
		/// </summary>
		public IDTO ReturnDTOItem { get; set; }
		/// <summary>
		/// The returned DTO list
		/// </summary>
		public List<IDTO> ReturnDTOList { get; set; }
	}

	#endregion

}
